package com.neoharvest.smartagri.service;

import java.util.HashMap;
import java.util.Map;

public class FieldMonitoringService {
    private Map<String, Double> soilData = new HashMap<>();
    
    public void updateSoilData(String type, double value) {
        soilData.put(type, value);
        System.out.println("Soil " + type + " updated to: " + value);
    }
    
    public double getSoilData(String type) {
        return soilData.getOrDefault(type, 0.0);
    }
    
    public void monitorSoil() {
        System.out.println("Monitoring soil conditions:");
        soilData.forEach((k,v) -> System.out.println(k + ": " + v));
    }
}